package com.example.ware.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.example.ware.model.po.Fireworks;
import com.example.ware.model.vo.FireWorksVo;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface FireWorksMapper extends BaseMapper<Fireworks> {

    @Select("select f.*,k.name as kname from fireworks f join kinds k on f.kid=k.id where f.name=#{name}  LIMIT #{pageNum}, #{pageSize}")
    public List<FireWorksVo> getListForName(String name, int pageNum, int pageSize);

    @Select("select f.*,k.name as kname from fireworks f join kinds k on f.kid=k.id   LIMIT #{pageNum}, #{pageSize}")
    public List<FireWorksVo> getList(int pageNum,int pageSize);

}
